Automatic music generating method and device

ABSTRACT

The invention concerns a music generating method which consists in: an operation defining musical moments during which at least four notes are capable of being played, for example, bars or half-bars; an operation defining two families of note pitches, for each musical moment, the second family of note pitches having at least one note pitch which does not belong to the first family; an operation forming at least a succession of notes having at least two notes, each succession of notes being called a musical phrase, succession wherein, for each moment, each note whereof the pitch belongs exclusively to the second family is exclusively surrounded with notes of the first family; and an operation producing the output of a signal representing each pitch of each succession of notes.

This application claims the benefit under 35 U.S.C. §365 ofInternational Application PCT/FR99/02262, filed Sep. 23, 1999, which waspublished in accordance with PCT Article 21(2) on Mar. 30, 2000 inFrench, and which claims the benefit of French Application No. 9812460,filed Sep. 24, 1998 and French Application No. 9908278, filed Jun. 23,1999.

BACKGROUND OF THE INVENTION

The present invention relates to an automatic music generation procedureand system. It applies, in particular, to the broadcasting of backgroundmusic, to teaching media, to telephone on-hold music, to electronicgames, to toys, to music synthesizers, to computers, to camcorders, toalarm devices, to musical telecommunication and, more generally, to theillustration of sounds and to the creation of music.

The music generation procedures and systems currently known use alibrary of stored musical sequences which serve as a basis formanipulating automatic random assemblies. These systems have three maintypes of drawback:

firstly, the musical variety resulting from the manipulation of existingmusical sequences is necessarily very limited;

secondly, the manipulation of parameters is limited to theinterpretation of the assembly of sequences: tempo, volume,transposition, instrumentation; and

finally, the memory space used by the “templates” (musical sequences) isgenerally very large (several megabytes).

These drawbacks limit the applications of the currently known musicgeneration systems to the non-professional illustration of sounds and todidactic music.

SUMMARY OF THE INVENTION

The present invention intends to remedy these drawbacks. For thispurpose, the subject of the present invention, according to a firstaspect, is an automatic music generation procedure, characterized inthat it comprises:

an operation of defining musical moments during which at least fournotes are capable of being played;

an operation of defining two families of note pitches, for each musicalmoment, the second family of note pitches having at least one note pitchwhich is not in the first family;

an operation of forming at least one succession of notes having at leasttwo notes, each succession of notes being called a musical phrase, inwhich succession, based on a phrase of at least three notes, each notewhose pitch belongs exclusively to the second family is surroundedexclusively by notes of the first family; and

an operation of outputting a signal representative of each note pitch ofeach said succession.

By virtue of these arrangements, the succession of note pitches has botha very rich variety, since the number of successions that can begenerated in this way is several thousands, and harmonic coherence,since the polyphony generated is governed by constraints.

According to particular characteristics during the operation of definingtwo families of note pitches, for each musical moment, the first familyis defined as a set of note pitches belonging to the current harmonicchord duplicated from octave to octave.

According to further particular characteristics, during the operation ofdefining two families of note pitches, the second family includes atleast the pitches, of a scale whose mode has been defined, which are notin the first family.

By virtue of these arrangements, the definition of the families is easyand the alternation of notes of the two families is harmonious.

According to further particular characteristics, during the operation offorming at least one succession of notes having at least two notes, eachmusical phrase is defined as a set of notes the starting times of whichare not mutually separated, in pairs, by more than a predeterminedduration.

By virtue of these arrangements, a musical phrase consists, for example,of notes the starting times of which are not separated by more thanthree semiquavers (or sixteenth notes).

According to further particular characteristics, the music generationprocedure furthermore includes an operation of inputting valuesrepresentative of physical quantities and in that at least one of theoperations of defining musical moments, by definition of two families ofnote pitches, formed from at least one succession of notes, is based onthe value of at least one value of a physical quantity.

By virtue of these arrangements, the musical piece may be put intorelationship with a physical event, such as an image, a movement, ashape, a sound, a keyed input, phases of a game whose physical quantityis representative, etc.

According to a second aspect, the subject of the invention is anautomatic music generation system, characterized in that it comprises:

a means of defining musical moments during which at least four notes arecapable of being played;

a means of defining two families of note pitches, for each musicalmoment, the second family of note pitches having at least one note pitchwhich is not in the first family;

a means of forming at least one succession of notes having at least twonotes, each succession of notes being called a musical phrase, in whichsuccession, for each moment, each note whose pitch belongs exclusivelyto the second family is surrounded exclusively by notes of the firstfamily; and

a means of outputting a signal representative of each note pitch of eachsaid succession.

The subject of the present invention, according to a third aspect, is amusic generation procedure, characterized in that it comprises:

an operation of processing information representative of a physicalquantity during which at least one value of a parameter called a“control parameter” is generated;

an operation of associating each control parameter with at least oneparameter called a “music generation parameter” each corresponding to atleast one note to be played during a musical piece; and

a music generation operation using each music generation parameter togenerate a musical piece.

By virtue of these arrangements, not only may a note depend on aphysical quantity, as in a musical instrument, but a music generationparameter relating to at least one note to be played depends on aphysical quantity.

According to particular characteristics, the music generation operationcomprises, successively:

an operation of automatically determining a musical structure composedof moments comprising bars (or mesures), each bar having times and eachtime having note start locations;

an operation of automatically determining densities, probabilities ofthe start of a note to be played, these being associated with eachlocation; and

an operation of automatically determining rhythmic cadences according todensities.

According to particular characteristics, the music generation operationcomprises:

an operation of automatically determining harmonic chords which areassociated with each location;

an operation of automatically determining families of note pitchesaccording to the rhythmic chord which is associated with a location; and

an operation of automatically selecting a note pitch associated witheach location corresponding to the start of a note to be played,according to said families and to rules of predetermined composition.

According to further particular characteristics, the music generationoperation comprises:

an operation of automatically selecting orchestral instruments;

an operation of automatically determining a tempo;

an operation of automatically determining the overall tonality of thepiece;

an operation of automatically determining an intensity for each locationcorresponding to the start of a note to be played;

an operation of automatically determining the duration of each note tobe played;

an operation of automatically determining rhythmic cadences ofarpeggios; and/or

an operation of automatically determining rhythmic cadences ofaccompaniment chords.

According to particular characteristics, during the music generationoperation each density depends on said tempo (speed of performing thepiece).

According to a fourth aspect, the subject of the invention is a musicgeneration procedure which takes into account a family of descriptors,each descriptor relating to several possible start locations of notes tobe played in a musical piece, said procedure comprising, for eachdescriptor, an operation of selecting a value, characterized in that,for at least some of said descriptors, said value depends on at leastone physical quantity.

According to a fifth aspect, the subject of the present invention is amusic generation system, characterized in that it comprises:

a means of processing information representative of a physical quantitydesigned to generate at least one value of a parameter called a “controlparameter”;

a means of associating each control parameter with at least oneparameter called a “music generation parameter” each corresponding to atleast one note to be played during a musical piece;

a music generation means using each music generation parameter togenerate a musical piece.

According to a sixth aspect, the subject of the invention is a musicgeneration system which takes into account a family of descriptors, eachdescriptor relating to several possible start locations of notes to beplayed in a musical piece, characterized in that it comprises a meansfor selecting, for each descriptor, a value dependent on at least onephysical quantity.

By virtue of each of these arrangements, the music generated isconsistent and pleasant to listen to, since the musical parameters arelinked together by constraints. In addition, the music generated isneither “gratuitous”, nor accidental, nor entirely random. Itcorresponds to external physical quantities and may even be made withoutany human assistance, by the acquisition of values of physicalquantities.

The subject of the present invention, according to a seventh aspect, isa music generation procedure, characterized in that it comprises:

a music generation initiation operation;

an operation of selecting control parameters;

an operation of associating each control parameter with at least oneparameter called a “music generation parameter” corresponding to atleast two notes to be played during a musical piece; and

a music generation operation using each music generation parameter togenerate a musical piece.

According to particular characteristics, the initiation operationcomprises an operation of connection to a network, for example theInternet network.

According to further particular characteristics, the initiationoperation comprises an operation of reading a sensor.

According to further particular characteristics, the initiationoperation comprises an operation of selecting a type of music.

According to further particular characteristics, the initiationoperation comprises an operation of selecting musical parameters by auser.

According to further particular characteristics, the music generationoperation comprises, successively:

an operation of automatically determining a musical structure composedof moments comprising bars, each bar having beats and each beat havingnote start locations;

an operation of automatically determining densities, probabilities ofthe start of a note to be played, these being associated with eachlocation;

an operation of automatically determining rhythmic cadences according todensities.

According to further particular characteristics, the music generationoperation comprises:

an operation of automatically determining harmonic chords which areassociated with each location;

an operation of automatically determining families of note pitchesaccording to the chord associated with a location, with the position ofthis location within the beat of one bar, with the occupancy of theadjacent positions and with the presence of the possible adjacent notes;

an operation of automatically selecting a note pitch associated witheach location corresponding to the start of a note to be played,according to said families and to predetermined composition rules.

According to further particular characteristics, the music generationoperation comprises:

an operation of automatically selecting orchestral instruments;

an operation of automatically determining a tempo;

an operation of automatically determining the overall tonality of thepiece;

an operation of automatically determining an intensity for each locationcorresponding to the start of a note to be played;

an operation of automatically determining the duration of each note tobe played;

an operation of automatically determining rhythmic cadences ofarpeggios; and/or

an operation of automatically determining rhythmic cadences ofaccompaniment chords.

According to further particular characteristics, during the musicgeneration operation each density depends on said tempo (speed ofperforming the piece).

According to an eighth aspect, the subject of the present invention is amusic generation system characterized in that it comprises:

a music generation initiation means;

a means of selecting control parameters;

a means of associating each control parameter with at least oneparameter called a “music generation parameter” corresponding to atleast two notes to be played during a musical piece;

a music generation means using each music generation parameter togenerate a musical piece.

According to a ninth aspect, the subject of the present invention is amusical coding procedure, characterized in that the coded parameters arerepresentative of a density, of a rhythmic cadence and/or of families ofnotes.

By virtue of each of these arrangements, the generated music isconsistent and pleasant to listen to, since the musical parameters arelinked together by control parameters. In addition, the music generatedis neither “gratuitous” nor accidental, nor entirely random. Itcorresponds to control parameters and may even be made without any humanassistance, by means of sensors.

These second to ninth aspects of the invention have the same particularcharacteristics and the advantages as the first aspect. These aretherefore not repeated here.

The subject of the invention is also a compact disc, an informationmedium, a modem, a computer and its peripherals, an alarm, a toy, anelectronic game, an electronic gadget, a postcard, a music box, acamcorder, an image/sound recorder, a musical electronic card, a musictransmitter, a music generator, a teaching book, a work of art, a radiotransmitter, a television transmitter, a television receiver, an audiocassette player, an audio cassette player/recorder, a video cassetteplayer, a video cassette player/recorder, a telephone, a telephoneanswering machine and a telephone switchboard, characterized in thatthey comprise a system as succinctly explained above.

The subject of the invention is also a digital sound card, an electronicmusic generation card, an electronic cartridge (for example for videogames), an electronic chip, an image/sound editing table, a computer, aterminal, computer peripherals, a video camera, an image recorder, asound recorder, a microphone, a compact disc, a magnetic tape, an analogor digital information medium, a music transmitter, a music generator, ateaching book, a teaching digital data medium, a work of art, a modem, aradio transmitter, a television transmitter, a television receiver, anaudio or video cassette player, an audio or video cassetteplayer/recorder and a telephone.

The subject of the invention is also:

a means of storing information that can be read by a computer or amicroprocessor storing instructions for a computer program,characterized in that it makes it possible for the procedure of theinvention, as succinctly explained above, to be implemented locally orremotely;

a means of storing information which is partially or completelyremovable and is readable by a computer or a microprocessor storinginstructions for a computer program, characterized in that it makes itpossible for the procedure of the invention, as succinctly explainedabove, to be implemented locally or remotely; and

a means of storing information obtained by implementation of theprocedure according to the present invention or use of a systemaccording to the present invention.

The preferred or particular characteristics, and the advantages of thiscompact disc, of this information medium, of this modem, of thiscomputer, of these peripherals, of this alarm, of this toy, of thiselectronic game, of this electronic gadget, of this postcard, of thismusic box, of this camcorder, of this image/sound recorder, of thismusical electronic card, of this music transmitter, of this musicgenerator, of this teaching book, of this work of art, of this radiotransmitter, of this television transmitter, of this televisionreceiver, of this audio cassette player, of this audio cassetteplayer/recorder, of this video cassette player, of this video cassetteplayer/recorder, of this telephone, of this telephone answering machine,of this telephone switchboard and of these information storage meansbeing identical to those of the procedure as succinctly explained above,these advantages are not repeated here.

BRIEF DESCRIPTION OF THE DRAWINGS

Further advantages and characteristics of the invention will becomeapparent from the description which follows, given with regard to theappended drawings in which:

FIG. 1 shows, schematically, a flow chart for automatic music generationin accordance with one method of implementing the procedure according tothe present invention;

FIG. 2 shows, in the form of a block diagram, one embodiment of a musicgeneration system according to the present invention;

FIG. 3 shows, schematically, a flow chart for music generation accordingto a first embodiment of the present invention;

FIGS. 4A and 4B show, schematically, a flow chart for music generationaccording to a second embodiment of the present invention;

FIG. 5 shows a flow chart for determining music generation parametersaccording to a third method of implementing the present invention;

FIG. 6 shows a system suitable for implementing the flow chartillustrated in FIG. 5;

FIG. 7 shows a flow chart for determining music generation parametersaccording to a fourth method of implementing the present invention;

FIG. 8 shows, schematically, a flow chart for music generation accordingto one aspect of the present invention;

FIG. 9 shows a system suitable for implementing the flow chartsillustrated in FIGS. 3, 4A, and 4B;

FIG. 10 shows an information medium according to one aspect of thepresent invention;

FIGS. 11 shows, schematically, a system suitable for carrying outanother method of implementing the procedure forming the subject of theinvention;

FIG. 12 shows internal structures of beats and of bars, together withtables of values, used to carry out the method of implementation usingthe system of FIG. 11;

FIGS. 13 to 23 show a flow chart for the method of implementationcorresponding to FIGS. 11 and 12; and

FIGS. 24 and 25 illustrate criteria for determining the family of notesat certain locations according to their immediate adjacency, forcarrying out the method of implementation illustrated in FIGS. 11 and23.

FIG. 1 shows, schematically, a flow chart for automatic music generationin accordance with one method of implementing the procedure according tothe present invention.

After the start 10, during an operation 12, musical moments are definedduring an operation 12. For example, during the operation 12, a musicalpiece comprising bars are defined, each bar including times and eachtime including note locations. In this example, the operation 12consists in assigning a number of bars to the musical piece, a number oftimes to each bar and a number of note locations to each time or aminimum note duration.

During operation 12, each musical moment is defined in such a way thatat least four notes are capable of being played over its duration.

Next, during an operation 14, two families of note pitches are definedfor each musical moment, the second family of note pitches having atleast one note pitch which is not in the first family. For example, ascale and a chord are assigned to each half-bar of the musical piece,the first family comprising the note pitches of this chord, duplicatedfrom octave to octave, and the second family comprising at least thenote pitches of the scale which are not in the first family. It may beseen that various musical moments or consecutive musical moments mayhave the same families of note pitches.

Next, during an operation 16, at least one succession of notes having atleast two notes is formed with, for each moment, each note whose pitchbelongs exclusively to the second family being surrounded exclusively bynotes of the first family. For example, a succession of notes is definedas a set of notes the starting times of which are not mutuallyseparated, in pairs, by more than a predetermined duration. Thus, in theexample explained with operation 14, for each half-bar, a succession ofnotes does not have two consecutive note pitches which are exclusivelyin the second family of note pitches.

During an operation 18, a signal representative of the note pitches ofeach succession is emitted. For example, this signal is transmitted to asound synthesizer or to an information medium. The music generation thenstops at the operation 20.

FIG. 2 shows, in the form of a block diagram, one embodiment of themusic generation system according to the present invention. In thisembodiment, the system 30 comprises, linked together by at least onesignal line 40, a note pitch family generator 32, a musical momentgenerator 34, a musical phrase generator 36 and an output port 38. Theoutput port 38 is linked to an external signal line 42.

The signal line 40 is a line capable of carrying messages orinformation. For example, it is an electrical or optical conductor ofknown type. The musical moment generator 34 defines musical moments insuch a way that four notes are capable of being played during eachmusical moment. For example, the musical moment generator defines amusical piece by a number of bars that it contains and, for each bar, anumber of beats, and for each beat, a number of possible note startlocations or minimum note duration.

The note pitch family generator 32 defines two families of note pitchesfor each musical moment. The generator 32 defines the two families ofnote pitches in such a way that the second family of note pitches has atleast one note pitch which is not in the first family of note pitches.For example, a scale and a chord are assigned to each half-bar of themusical piece, the first family comprising the note pitches of thischord, duplicated from octave to octave, and the second familycomprising at least the note pitches of the scale which are not in thefirst family. It may be seen that various musical moments or consecutivemusical moments may have the same families of note pitches.

The musical phrase generator 36 generates at least one succession ofnotes having at least two notes, each succession being formed in such away that, for each moment, each note whose pitch belongs exclusively tothe second family is surrounded exclusively by notes of the firstfamily. For example, a succession of notes is defined as a set of notesthe starting times of which are not mutually separated, in pairs, bymore than a predetermined duration. Thus, in the example explained withthe note pitch family generator 32, for each half-bar, a succession ofnotes does not have two consecutive note pitches which are exclusivelyin the second family of note pitches.

The output port 38 transmits, via the external signal line 42, a signalrepresentative of the note pitches of each succession is emitted. Forexample, this signal is transmitted, via the external line 42, to asound synthesizer or to an information medium.

The music generation system 30 comprises, for example, a general-purposecomputer programmed to implement the present invention, a MIDI soundcard linked to a bus of the computer, a MIDI synthesizer linked to theoutput of the MIDI sound card, a stereo amplifier linked to the audiooutputs of the MIDI synthesizer and speakers linked to the outputs ofthe stereo amplifier.

In the description of the second and third method of implementation, andin particular in the description of FIGS. 3, 4A and 4B, the expression“randomly or nonrandomly” is used to express the fact that,independently of one another, each parameter to which this expressionrefers may be selected randomly or be determined by a value of aphysical quantity (for example one detected by a sensor) or a choicemade by a user (for example by using the keys of a keyboard), dependingon the various methods of implementing the present invention.

As illustrated in FIG. 3, in a second simplified method ofimplementation for the purpose of only generating and playing themelodic line (or song), the procedure according to the present inventioncarries out:

an operation 102 of determining, randomly or nonrandomly, the shortestduration that a note can have in the musical piece and the maximuminterval, expressed as the number of semitones between two consecutivenote pitches (see operation 114);

an operation 104 of determining, randomly or nonrandomly, on a timescale, the number of occurrences of each element (introduction,semi-couplets, couplets, refrains, semi-refrains, finale) of a musicalpiece and the identities between these elements, a number of bars whichmake up each element, a number of beats which make up each bar and anumber of time units, called hereafter “positions” or “locations”, eachtime location having a duration equal to the shortest note to begenerated, for each beat;

an operation 106 of defining, randomly or nonrandomly, a density valuefor each location of each element of the piece, the density of alocation being representative of the probability that, at this timelocation, a note of the melody is positioned thereat (that it to say,for the playing phase, that the note starts to be played);

an operation 108 of generating a rhythmic cadence which determines,randomly or nonrandomly, for each position or location, depending on thedensity associated with this position or with this location duringoperation 106, whether a note of the melody is positioned thereat, ornot;

an operation 110 of copying rhythmic sequences corresponding to similarrepeated elements (refrains, couplets, semi-refrains, semi-couplets) ofthe musical piece or to identical elements (introduction, finale),(thus, at the end of operation 110, the positions of the notes aredetermined but not their pitch, that is to say their fundamentalfrequency);

an operation 112 of assigning note pitches to the notes belonging to therhythmic cadence, during which:

during an operation 112A, for each half-bar, two families of notepitches (for example, the first family composed of note pitchescorresponding to a chord of a scale, possibly duplicated from octave tooctave, and the second family composed of note pitches of the same scalewhich are not in the first family) are determined randomly ornonrandomly and

during an operation 112B, for each set of notes (called hereafter amusical phrase or succession), the starting times of which are notmutually separated, in pairs, by more than a predetermined duration(corresponding, for example, to three positions), note pitches of thefirst family of notes are randomly assigned to the even-rank locationsin said succession and note pitches of the second family of notes arerandomly assigned to the odd-rank locations in said succession (it maybe seen that if the families change during the succession, for exampleat the half-bar change, the rule continues to be observed throughout thesuccession);

a filtering operation 114, possibly integrated into the note-pitchassignment operation 112, during which if two consecutive note pitchesin the succession are spaced apart by more than the interval determinedduring operation 102, expressed as the number of semitones, the pitch ofthe second note is randomly redefined and operation 114 is repeated;

an operation 116 of assigning a note pitch to the last note of thesuccession, the note pitch being taken from the first family of notepitches; and

a play operation 120 carried out by controlling a synthesizer module insuch a way that it plays the melodic line defined during the aboveoperations and a possible orchestration.

During operation 120, the durations for playing the notes of the melodyare selected randomly without, however, making the playing of twoconsecutive notes overlap—the intensities of the note pitches areselected randomly. The durations and intensities are repeated for eachelement copied during operation 110 and an automatic orchestration isgenerated in a known manner. Finally, the instruments of the melody andof the orchestra are determined randomly or nonrandomly.

In the method of implementation illustrated in FIG. 3, there is only onetype of intensity: the notes placed off the beat are played with greaterstress than the notes placed on the beat. However, a random selectionseems more human. For example, if the aim is to have a mean intensity of64 for a note positioned at the first location of a beat, an intensityof between 60 and 68 per beat is randomly selected. If the aim is tohave a mean intensity of 76 for a note positioned at the third locationof a beat, an intensity of between 72 and 80 is randomly selected forthis note. For the notes positioned at the second and fourth locationsof the beat, an intensity value which depends on the intensity of theprevious or following note and lower than this reference intensity ischosen. As an exception, a note at the start of a musical phrase, if itspitch is in the first family of note pitch, a high intensity, forexample 85, is chosen. Also as an exception, the last note in a musicalphrase is associated with a low intensity, for example 64.

The following intensities are chosen, for example, for the variousaccompaniment instruments:

for the bass notes: the notes placed on the beat are stressed more thanthose placed off the beat, the rare intermediate notes being stressedeven more;

arpeggios: the same as for the base notes, except that the intermediatenotes are less stressed;

rhythmic chords: the notes placed on the beat are stressed less thanthose placed off the beat, the intermediate notes being even lessstressed; and

thirds: lower intensities than those of the melody, but proportional tothe intensities of the melody, note by note. If the couplet is playedtwice, the intensities are repeated for the same notes and the sameinstruments. The same applies to the refrain.

With regard to the durations of the notes played, they are selectedrandomly with weightings which depend on the number of locations in thebeats. When the duration available before the next note is one unit oftime, the duration of the note is one unit of time. When the availableduration is two units of time, a random selection is made between thefollowing durations: a complete quaver (5 chances in 6) or a semiquaverfollowed by a semiquaver rest (1 chance in 6). When the availableduration is three units of time, a random selection is made between thefollowing durations: a complete dotted quaver (4 chances in 6), a quaverfollowed by a semiquaver rest (2 chances in 6). When the availableduration is 4 units of time, a random selection is made between thefollowing durations: a complete crotchet (7 chances in 10), a dottedquaver followed by a semiquaver rest (2 chances in 10) or a quaverfollowed by a quaver rest (1 chance in 10). When the available durationis greater than 4 units of time, a random selection is made so as tochoose the complete available duration (2 chances in 10), half theavailable duration (2 chances in 10), a crotchet (2 chances in 10), ifthe available duration so allows, a minim (2 chances in 10) or asemibreve or whole note (2 chances in 10). If there is a change infamily during a musical phrase, the playing of the note is stoppedexcept if the note belongs to the equivalent families before and afterthe change in family.

It may be seen that, as a variant, during operation 112A, the secondfamily of note pitches possibly includes at least one note pitch of thefirst family and during operations 112B and 114 the note pitches of eachsuccession are defined in such a way that two consecutive notes of thesame half-bar and of the same succession cannot belong exclusively tothe second family of note pitches.

As illustrated in FIGS. 4A and 4B, in a third method of embodiment, theprocedure and the system of the present invention carry out operationsof determining:

A/the structure within the beat, comprising:

an operation 202 of defining, randomly or nonrandomly, a maximum numberof locations or positions (each corresponding to the minimum duration ofa note in the piece) to be played per beat, here, for example, 4locations called successively e1, e2, e3 and e4;

B/the structure within the bar, comprising:

an operation 204 of defining, randomly or nonrandomly, the number ofbeats per bar, here, for example, 4 beats per bar, which thereforecorresponds to 16 positions or locations;

C/the overall structure of the piece, comprising:

an operation 206 of defining, randomly or nonrandomly, the durations ofthe elements of the musical piece (refrain, semi-refrain, couplet,semi-couplet, introduction, finale), in terms of numbers of bars, andthe number of repeats of the elements in the piece; here, theintroduction has a duration of 2 bars, the couplet a duration of 8 bars,the refrain a duration of 8 bars, each refrain and each couplet beingplayed twice, and the finale being the repetition of the refrain;

D/the instrumentation, comprising:

an operation 208 of determining, randomly or nonrandomly, an orchestracomposed of instruments accompanied by setting values (overall volume,reverberation, echoes, panning, envelope, clarity of sound, etc.);

E/the tempo, comprising:

an operation 210 of generating, randomly or nonrandomly, a speed ofexecution of the playing;

F/the tonality, comprising:

an operation 212 of generating, randomly or nonrandomly, a positive ornegative transposition value, the base tonality, the transposition valueof which is “zero” being, arbitrarily, C major; the transposition is avalue which shifts the melody and its accompaniment by one or moretones, upward or downward, with respect to the first tonality (stored inthe random memory). The percussion part is not affected by thetransposition. This “transposition” value is repeated during theinterpretation step and is added to each note pitch just before they aresent to the synthesizer (except on the percussion “track”) and thisvalue may be, as here, constant throughout the duration of the piece, ormay vary for a change of tone, for example during a repeat;

G/the harmonic chords, comprising:

an operation 214 of selecting, randomly or nonrandomly, a chordselection mode from two possible modes:

if the first chord selection mode is selected, an operation 216 ofselecting, randomly or nonrandomly, harmonic chords,

if the second chord selection mode is selected, an operation 218 ofselecting, randomly or nonrandomly, harmonic chord sequences, on the onehand, for the refrain and, on the other hand, for the couplet.

Thus, the chord sequence is formed:

either by a random or nonrandom selection, chord by chord (each chordselected being chosen or rejected depending on the constraints accordingto the rules of the musical art); however, in other methods ofimplementation, this chord sequence may either be input by theuser/composer or generated by the harmonic consequence of a dense firstmelodic line (for example, two, three, four notes per beat) having analgorithmic character (for example, a fugue) or not, and the notes ofwhich are output (by random or nonrandom selection) from scales and fromharmonic modes chosen randomly or nonrandomly;

or by random or nonrandom selection of a group of eight chords stored inmemory from a hundred or so other groups. Since each chord relates hereto a bar, a group of eight chords relates to eight bars.

In the method of implementation described and shown, the invention isapplied to the generation of songs and the harmonic chords used arechosen from perfect minor and major chords, diminished chords, anddominant seventh, eleventh, ninth and major seventh chords.

H/the melody, comprising:

H1/the rhythmic cadence of the melody, including an operation 220 ofassigning, randomly or nonrandomly, densities to each location of anelement of the musical piece, in this case to each location of a refrainbeat and to each location of a couplet beat, and then of generating,randomly or nonrandomly, three rhythmic sequences of two bars each, thecouplet receiving the first two rhythmic cadences repeated 2 times andthe refrain receiving the third rhythmic cadence repeated 4 times. Inthe example described and shown in FIG. 4, the locations e1 and e3 have,averaged over all the density selections, a mean density (for example ofthe order of magnitude of ?) greater than the locations e2 and e4 (forexample of the order of magnitude of ⅕). However, each density isweighted by a multiplicative coefficient inversely proportional to thespeed of execution of the piece (the higher the speed, the lower thedensity);

H2/the note pitches, including an operation 222 of selecting notepitches defined by the rhythmic cadence. During this operation 222, twofamilies of note pitches are formed. The first family of note pitchesconsists of the note pitches of the harmonic chord associated with theposition of the note and the second composed of the note pitches of thescale of the overall basic harmony (the current tonality) reduced (or,as a variant, not reduced) by the note pitches of the first family ofnote pitches. During this operation 222, at least one of the followingconstraint rules is applied to the choice of note pitches:

there is never a succession of two notes which are exclusively in thesecond family,

the pitches of the notes selected for the locations el (positions 1, 5,9, 13, 17, etc.) always belong to the first family (apart fromexceptional cases, that is to say in less than one quarter of thecases),

two starts of notes placed in two successive positions belongalternately to one of the two families of note pitches and then to theother (“alternation rule”),

when there is no start of a note to be played at the locations e2 ande4, the note pitch of the possible note which starts at e3 is in thesecond family of note pitches,

the last note of a succession of note starts, followed by at least threepositions without a note start, has a note pitch in the first family(via a local violation of the alternation rule),

the note pitch at e4 belongs to the first note family when there is achange of harmonic chord at the next position (e1) (via a localviolation at e4 of the alternation rule) and

the pitch interval between note starts in two successive positions islimited to 5 semitones;

H3/the intensity of the notes of the melody, including an operation 224of generating, randomly or nonrandomly, the intensity (volume) of thenotes of the melody according to their location in time and to theirposition in the piece;

H4/the durations of the notes, including an operation 226 of generating,randomly or nonrandomly, the end time of each note played;

I/the musical arrangement, comprising:

an operation 228 of generating, randomly or nonrandomly, two rhythmiccadences of the notes of arpeggios, having the lengths of a bar each,the first being coupled so as to be associated with the entire coupletand the second being copied so as to be associated with the entirerefrain,

an operation 230 of generating, randomly or nonrandomly, note pitches ofarpeggios from the note pitches of the first family of note pitches,with an interval between two successive note pitches of less than orequal to 5 semitones;

an operation 232 of generating, randomly or nonrandomly, the intensities(volume) of the notes of arpeggios. Thus, each of the two “arpeggio”rhythmic cadences of a bar receives intensity values at the locations ofthe notes “to be played”. Each of the two arpeggio intensity values isdistributed (copied) over the part of the piece in question: one overthe couplet and the other over the refrain;

an operation 234 of generating, randomly or nonrandomly, durations ofarpeggio notes;

an operation 236 of generating, randomly or nonrandomly, two rhythmiccadences for the playing of harmonic chords, copied so as to be spread,one over the couplet and the other over the refrain, arrangement chordswhich are played when the arpeggios are not played (the rhythmic cadenceof the accompaniment chords, for example played by the guitar, receivesrandom or nonrandom values according to the same method as the rhythmiccadences of arpeggio notes. These values initiate or do not initiate theplaying of the accompaniment guitar. If, at the same moment, an arpeggionote has to be played, the chord has priority and the arpeggio note iscanceled);

an operation 238 of generating, randomly or nonrandomly, the intensitiesof rhythmic chords;

an operation 240 of generating, randomly or nonrandomly, chordinversions; and

J/the playing of the piece, comprising an operation 242 of transmittingto a synthesizer all the setting values and the values for playing thevarious instruments defined during the previous operations.

In the second method of implementation described and shown, a musicalpiece is composed and interpreted using the MIDI standard. MIDI is theabbreviation for “Musical Instrument Digital Interface” (and which meansthe digital communication interface between musical instruments). Thisstandard employs:

a physical connection between the instruments, which takes the form of atwo-way serial interface via which the information is transmitted at agiven rate; and

a standard for information exchange (“general MIDI”) via the cableslinked to the physical connections, the meaning of predetermined digitalsequences corresponding to predefined actions of the musical instruments(for example, in order to play the note “middle C” of the keyboard inthe first channel of a polyphonic synthesizer, the sequence 144, 60,80). The MIDI language relates to all the parameters for playing a note,for stopping a note, for the pitch of a note, for the choice ofinstrument and for setting the “effects” of the sound of the instrument:

reverberation, chorus effect, echoes, panning, vibrato, glissando.

These parameters suffice for producing music with several instruments:MIDI uses 16 parallel polyphonic channels. For example, with the G800system of the ROLAND brand, 64 notes played simultaneously can beobtained.

However, the MIDI standard is only an intermediate between the melodygenerator and the instrument.

If a specific electronic circuit (for example of the ASIC—ApplicationSpecific Integrated Circuit—type) were to be used, it would no longer beessential to comply with the MIDI standard.

In parallel with the playing phase is an actual interpretation phase,the interpretation being by means of random or nonrandom variations, inreal time, carried out note by note, on the expression, vibrato,panning, glissasndo and intonation, for all of the notes of eachinstrument.

It may be seen here that all the random selections are based on integernumbers, possibly negative numbers, and that a selection from aninterval bounded by two values may give one of these two values.Preferably, the scale of pitch notes of the melody is limited to thetessitura of the human voice. The note pitches are therefore distributedover a scale of about one and a half octaves, i.e. in MIDI language,from note 57 to note 77. As regards note pitches of the bass line (forexample the contrabass), in the method of implementation described, theplaying of the bass plays once per beat and on the beat (location “e1”).Moreover, a playing correlation is established with the melody: when theintensity of a note of the melody exceeds a certain threshold, thisresults in the generation of a possibly additional note of the basswhich may not be located on the beat, but at the half-beat (location“e3”) or at intermediate locations (locations “e1” and “e4”). The pitchof this possibly additional bass note has the same pitch as that of themelody but two octaves lower (in MIDI language, note 60 thus becomes36).

FIG. 5 shows a fifth and a sixth method of implementing the presentinvention, in which at least one physical quantity (in this case, anitem of information representative of an image) influences at least oneof the musical parameters used for the automatic music generationaccording to the present invention.

As illustrated in FIG. 5, in a fifth method of implementation combinedwith the third method of implementation (FIG. 3), at least one of thefollowing music generation parameters:

the shortest duration that a note may have in the musical work,

the number of time units per beat,

the number of beats per bar,

a density value associated with each location,

the first family of note pitches,

the first family of note pitches,

the predetermined interval or number of semitones which constitutes themaximum interval between two consecutive note pitches, is representativeof a physical quantity, here an optical physical quantity represented byan image information source.

As illustrated in FIG. 5, in a sixth method of implementation combinedwith the fourth method of implementation (FIGS. 4A and 4B), at least oneof the following music generation parameters:

number of locations or positions per beat,

number of beats per bar,

duration of a refrain,

duration of a couplet,

duration of the introduction,

duration of the finale,

number of repeats of the elements of the piece,

the choice of orchestra,

the settings of the instruments of the orchestra (overall volume,reverberation, echoes, panning, envelope, clarity of sound, etc.),

the tempo,

the tonality,

the selection of the harmonic chords,

a density associated with a location,

for each location, each family of note pitches,

each rule applicable or not applicable to the note pitches,

the maximum pitch interval between two successive note pitches,

the intensity associated with each location,

the duration of the notes,

the densities associated with the locations for the arpeggios,

the intensity associated with each location for the arpeggios,

the duration of the arpeggio notes,

the densities associated with the locations for the harmonic chords and

the intensity associated with each location for the rhythmic chords, isrepresentative of a physical quantity, here an optical physical quantityrepresented by an image information source. Thus, in FIG. 5, during anoperation 302, an operating mode is selected between a sequence-and-songoperating mode and a “with the current” operating mode, by progressivemodification of music generation parameters. When the first operatingmode is selected, during an operation 304, the user selects a durationof the musical piece in selects, with a keyboard (FIG. 6), the start andend of a sequence of moving images. Then, during an operation 306, asequence of images or the last ten seconds of images coming from a videocamera or from an image storage device (for example, a video taperecorder, a camcorder or a digital information medium reader) isprocessed using image processing techniques known to those skilled inthe art, in order to determine at least one of the following parameters:

the mean luminance of the image;

the change in mean luminance of the image;

frequency of large luminance variation;

amplitude of luminance variation;

mean chrominance of the image;

change in the mean chrominance of the image;

frequency of large chrominance variation;

amplitude of chrominance variation;

duration of the shots (detected by a sudden change between twosuccessive images of mean luminance and/or of mean chrominance);

movements in the image (camera or object).

Next, during an operation 308, each parameter value determined duringthe operation 306 is put into correspondence with at least one value ofa music generation parameter described above.

Next, during an operation 310, a piece (first operating mode) or twoelements (refrain and couplet, second operating mode) of a piece aregenerated in accordance with the associated method of music generationimplementation (third and fourth methods of implementation, illustratedin FIGS. 3 and 4).

Finally, during an operation 312, the music piece generated is playedsynchronously with display of the moving image, stored in an informationmedium.

In the second operating mode (gradually changing “with the current”music generation), the music generation parameters changes graduallyfrom one musical moment to the next.

FIG. 6 shows, for carrying out the various methods of implementing themusic generation procedure of the present invention which areillustrated in FIGS. 3 to 5, linked together by a data and address bus401:

a clock 402, which determines the rate of operation of the system;

an image information source 403 (for example, a camcorder, a video taperecorder or a digital moving-image reader);

a random-access memory 404 in which intermediate processing data,variables and processing results are stored;

a read-only memory 405 in which the program for operating the system isstored;

a processor (not shown) which is suitable for making the system operateand for organizing the datastreams on the bus 401, in order to executethe program stored in the memory 405;

a keyboard 407 which allows the user to choose a system operating modeand, optionally, to designate the start and end of a sequence (firstoperating mode);

a display 408 which allows the user to communicate with the system andto see the moving image displayed;

a polyphonic music synthesizer 409; and

a two-channel amplifier 411, linked to the output of the polyphonicmusic synthesizer 409, and two loudspeakers 410 linked to the output ofthe amplifier 411.

The polyphonic music synthesizer 409 uses the functions and systemsadapted to the MIDI standard allowing it to communicate with othermachines provided with this same implantation and thus to understand theGeneral MIDI codes which denote the main parameters of the constituentelements of a musical work, these parameters being delivered by theprocessor 406 via a MIDI interface (not shown).

As an example, the polyphonic music synthesizer 409 is of the ROLANDbrand with the commercial reference E70. It operates with threeincorporated amplifiers each having a maximum output power of 75 wattsfor the high-pitched and medium-pitched sounds and of 15 watts for thelow-pitched sound.

As illustrated in FIG. 7, in a seventh method of implementation combinedwith the method of implementation illustrated in FIG. 3, at least one ofthe following music generation parameters:

the shortest duration that a note may have in the musical work,

the number of time units per beat,

the number of beats per bar,

a density value associated with each location,

the first family of note pitches,

the first family of note pitches,

the predetermined interval or number of semitones which constitutes themaximum interval between two consecutive note pitches, is representativeof a physical quantity coming from a sensor, in this case an imagesensor.

As illustrated in FIG. 7, in an eighth method of implementation combinedwith the method of implementation illustrated in FIGS. 4A and 4B, atleast one of the following music generation parameters:

number of locations or positions per beat,

number of beats per bar,

duration of a refrain,

duration of a couplet,

duration of the introduction,

duration of the finale,

number of repeats of the elements of the pieces,

the choice of orchestra,

the settings of the instruments of the orchestra (overall volume),reverberation, echoes, panning, envelope, clarity of sound, etc.),

the tempo,

the tonality,

the selection of the harmonic chords,

a density associated with a location,

for each location, each family of note pitches,

each rule applicable or not applicable to the note pitches,

the maximum pitch interval between the two pitches of consecutive notes,

the intensity associated with each location,

the duration of the notes,

the densities associated with the locations for the arpeggios,

the intensity associated with each location for the arpeggios,

the duration of the arpeggio notes,

the densities associated with the locations for the harmonic chords, and

the intensity associated with each location for the rhythmic chords, isrepresentative of a physical quantity coming from a sensor, in this casean image sensor.

Thus, in FIG. 7, during an operation 502, the image coming from a videocamera or a camcorder is processed using image processing techniquesknown to those skilled in the art, in order to determine at least one ofthe following parameters corresponding to the position of the user'sbody, and preferably the position of his hands, on a monochrome(preferably white) background:

mean horizontal position of the conductor's body, hands or baton;

mean vertical position of the conductor's body, hands or baton;

range of horizontal positions (standard deviation) of the conductor'sbody, hands or baton;

range of vertical positions (standard deviation) of the conductor'sbody, hands or baton;

mean slope of the cloud of positions of the conductor's body, hands orbaton; and

movement of the mean vertical and horizontal positions (defining thefour location in a beat and the intensities associated with theselocations).

Then, during an operation 504, each parameter value determined duringoperation 502 is brought into correspondence with at least one value ofa music generation parameter described above.

Next, during an operation 506, two elements (refrain and couplet) of apiece are generated in accordance with the associated method of musicgeneration implementation (second or third method of implementation,illustrated in FIGS. 3 and 4).

Finally, during an operation 508, the music piece generated is played orstored in an information medium. The music generation parameters(rhythmic cadence, note pitches, chords) corresponding to a copied part(refrain, couplet, semi-refrain, semi-couplet or movement of a piece)gradually change from one musical moment to the next, while theintensities and durations of the notes change immediately in relationwith the parameters picked up.

It may be seen that the embodiment of the system illustrated in FIG. 6is tailored to carrying out the fourth method of implementing the musicgeneration procedure of the present invention, illustrated in FIG. 7.

In the same way as explained with regard to FIGS. 5 to 7, and accordingto arbitrary correspondence settings, sensors of physical quantitiesother than image sensors may be used according to other methods ofimplementing the present invention. Thus, in another method ofimplementing the present invention, sensors for detecting physiologicalquantities of the user's body, such as:

an actimeter,

a tensiometer,

a pulse sensor,

a sensor for detecting rubbing, for example on sheets or a pillow (inorder to form a wake-up call following the wake-up of the user),

a sensor for detecting pressure at various points on gloves and/orshoes, and

a sensor for detecting pressure on arm and/or leg muscles, are used togenerate values of parameters representative of physical quantitieswhich, once they have been brought into correspondence with musicgeneration parameters, make it possible to generate musical pieces.

In another method of implementation, not shown, the parametersrepresentative of a physical parameter are representative of the user'svoice, via a microphone. In one example of carrying out a method ofimplementation, a microphone is used by the user to hum part of amelody, for example a couplet, and analysis of his voice gives values ofthe music generation parameters directly, in such a way that the piececomposed includes that part of the melody hummed by the user.

Thus, the following music generation parameters can be obtained directlyby processing the signal output by a microphone:

translation into MIDI language of the notes of a melody sung;

tempo (speed of execution);

maximum pitch interval between two notes played successively;

tonality;

harmonic scale;

orchestra;

intensities of the locations;

densities of the locations;

durations of the notes.

In another method of implementation, not shown, which may or may not beassociated or previous method of implementation, a text is supplied bythe user and a vocal synthesis system “sings” this text to the melody.

In another method of implementation, not shown, the user uses akeyboard, for example a computer keyboard, to make all or some of themusic generation parameter choices.

In another method of implementation, not shown, the values of musicalparameters are determined according to the lengths of text phrases, tothe words used in this text, to their connotation in a dictionary oflinks between text, emotion and musical parameter, to a number of feetby line, to the rhyming of this text, etc. This method of implementationis favorably combined with other methods of implementation explainedabove.

In another method of implementation, not shown, the values of musicalparameters are determined according to graphical objects used in adesign or graphics software package, according to mathematical curves,to the results in a tabling software package, to the replies to aplayful questionnaire (choice of animal, flower, name, country, color,geometrical shape, object, style, etc.) or to the description of agastronomic menu.

In another method of implementation, not shown, the values of themusical parameters are determined according to one of the followingprocessing operations:

image processing of a painting;

image processing of a sculpture;

image processing of an architectural building;

processing of signals coming from olfactory or gustatory sensors (inorder to associate a musical piece with a wine in which at least onegustatory sensor is positioned, or with a perfume).

Finally, in a method of implementation not shown, at least one of theautomatic music generation parameters depends on at least one physicalparameter, which is picked up by a video game sensor, and/or on asequence of a game in progress.

In a method of implementation illustrated in FIG. 9, the presentinvention is applied to a movable music generation system, such as a carradio or a Walkman.

This movable music generation system comprises, linked together via adata and control bus 700:

an electronic circuit 701, which carries out the operations illustratedin FIG. 3 or the operations illustrated in FIGS. 4A and 4B, in order togenerate a stereophonic audio signal;

a nonvolatile memory 702;

a program selection key 703;

a key 704 for switching to the next piece;

a key 705 for storing a musical piece in the memory;

at least one sensor 706 for detecting traffic conditions; and

two electroacoustic transducers 707 which broadcast the music (in thecase of the application to a Walkman, these transducers are smallloudspeakers integrated into earphones and in the application to a carradio, these transducers are loudspeakers built into the passengercompartment of a vehicle).

In the embodiment of the invention illustrated in FIG. 9, the key 705for storing a musical piece in memory is used to write into thenonvolatile memory 702 the parameters of the musical piece beingbroadcast. In this way, the user appreciating more particularly amusical piece can save it in order to listen to it again subsequently.

The program selection key 703 allows the user to choose a program type,for example depending on his physical condition or on the trafficconditions. For example, the user may choose between three programtypes:

a “wake-up” program, intended to wake him up or to keep him awake, inwhich program the pieces are particularly rhythmic;

a “cool-driver” program intended to relax him (for example in trafficjams), in which program the pieces are calm and slower than in the“wake-up” program (and are intended to reduce the impatience connectedwith traffic jams); and

an “easy-listening” program, mainly comprising cheerful music. The key704 for switching to the next piece allows the user not enjoying a piecehe is listening to to switch to a new piece.

Each traffic condition sensor 706 delivers a signal representative ofthe traffic conditions. For example the following sensors may constitutesensors 706:

a clock, which determines the duration of driving the vehicle or devicesince the last time it has stopped (this duration being representativeof the state of fatigue of the user);

a speed sensor, linked to the vehicle's speedometer, which determinesthe average speed of the vehicle over a duration of a few minutes (forexample, the last five minutes) in order, depending on predeterminedthresholds (for example 15 km/h and 60 km/h), to determine whether thevehicle is in heavy (congested) traffic, moderate traffic (without anycongestion) or on a clear highway;

a vibration sensor, which measures the average intensity of vibrationsin order to determine the traffic conditions (repeated stoppages indense traffic, high vibrations on a highway) between the pieces;

a sensor for detecting which gearbox gear is selected (frequentlychanging into first or second gear corresponding to traffic in an urbanregion or congested traffic, whereas remaining in one of the two highestgears corresponding to traffic on a highway);

a sensor for detecting the weather conditions, external temperature,humidity and/or rain detector;

a sensor for detecting the temperature inside the vehicle;

a clock giving the time of day; and

more specifically suitable for a Walkman, a podometer which senses therhythm of the walking.

Depending on the signals coming from each sensor 706 (these possiblybeing compared with values of previously stored signals), and if theuser has not chosen a music program, this is selected by the electroniccircuit 701.

FIG. 8 shows, schematically, a flow chart for music generation accordingto one aspect of the present invention, in which, during an operation600, the user initiates the music generation process, for example bysupplying electrical power to the electronic circuits and by pressing ona music generation selection key.

Next, during a test 602, it is determined whether the user can selectmusical parameters, or not. When the result of the test 602 is positive,during an operation 604, the user has the possibility of selectingmusical parameters, for example via a keyboard, potentiometers,selectors or a voice recognition system, by choosing a page of aninformation network site, for example the Internet network, depending onthe signals emitted by sensors.

Operations 600 to 604 together constitute an initiation operation 606.When the user has selected each musical parameter that he can select orwhen a predetermined duration has elapsed without the user havingselected a parameter, or else when the result of the test 602 isnegative, during an operation 608, the system determines randomparameters, including for each parameter which could have been selectedbut which has not yet been selected during operation 604.

During an operation 610, each random or selected parameter is put intocorrespondence with a music generator parameter, depending on the methodof implementation used (for example one of the methods of implementationillustrated in FIGS. 3 or 4A and 4B).

During an operation 612, a piece is generated by using the musicalparameters selected during operation 604 or generated during operation606, depending on the method of implementation used. Finally, during anoperation 614, the musical piece generated is played as explained above.

FIG. 10 shows a method of implementing the present invention, applied toan information medium 801, for example a compact disc (CD-ROM, CD-I,DVD, etc.). In this method of implementation, the parameters of eachpiece, which were explained with regard to FIGS. 3, 4A and 4B, arestored in the information medium and allow a saving of 90% of thesound/music memory space, compared with music compression devicescurrently used.

Likewise, the present invention applies to networks, for example theInternet network, for transmitting music for accompanying “web” pages,without transferring the voluminous “MIDI” or “audio” files; only apredetermined play order (predetermined by the “Web Master”) of a fewbits is transmitted to a system using the invention, which may or maynot be integrated into the computer, or quite simply to a musicgeneration (program) “plug in” coupled with a simple sound card.

In another method of implementation, not shown, the invention is appliedto toilets and the system is turned on by a sensor (for example, acontact) which detects the presence of a user sitting on the toiletbowl.

In other methods of implementation, not shown, the present invention isapplied to an interactive terminal (sound illustration), to an automaticdistributor (background music) or to an input ringing tone (so as tovary the sound emission of these systems, while calling the attention oftheir user).

In another method of implementation of the present invention, not shown,the melody is input by the user, for example by the use of a musicalkeyboard, and all the other parameters of the musical piece (musicalarrangement) are defined by the implementation of the present invention.

In another method of implementation, not shown, the user dictates therhythmic cadence and the other musical parameters are defined by thesystem forming the subject of the present invention.

In another method of implementation of the present invention, not shown,the user selects the number of playing points, for example according tophonemes, syllables or words of a spoken or written text.

In another method of implementation, not shown, the present invention isapplied to a telephone receiver, for example to control a musicalringing tone customized by the subscriber.

According to a variant, the musical ringing tone is automaticallyassociated with the telephone number of the caller.

According to another variant, the music generation system is included ina telephone receiver or else located in a datacom server linked to thetelephone network.

In another method of implementation, not shown, the user selects chordsfor generating the melody. For example, the user can select up to 4chords per bar.

In another method of implementation not shown, the user selects aharmonic grid and/or a bar repeat structure.

In another method of implementation not shown, the user selects or playsthe playing of the bass, and the other musical parameters are selectedby the system forming the subject of the present invention.

In another method of implementation of the present invention, not shown,a software package is downloaded into the computer of a person using acommunication network (for example the Internet network) and thissoftware package allows automatic implementation, either via initiationby the user or via initiation by a network server, of one of the methodsof implementing the invention.

According to a variant not shown, when a server transmits an Internetpage, it transmits all or some of the musical parameters of theaccompanying music intended for accompanying the reading of the page inquestion.

In a method of implementation not shown, the present invention is usedtogether with a game, for example a video game or a portable electronicgame, in such a way that at least one of the parameters of the musicalpieces played depends on the phase of the game and/or on the player'sresults, while still ensuring diversity between the successive musicalsequences.

In another method of implementation, not shown, the present invention isapplied to a telephone system, for example a telephone switchboard, inorder to broadcast diversified and harmonious on-hold music.

According to a variant, the listener changes piece by pressing on a keyof the keyboard of his telephone, for example the star key or the hashkey.

In another method of implementation, not shown, the present invention isapplied to a telephone answering machine or to a message service, inorder to musically introduce the message from the owner of the system.

According to a variant, the owner changes piece by pressing a key on thekeyboard of the answering machine.

According to a variant not shown, the musical parameters are modified ateach call.

In a method of implementation not shown, the system or the procedureforming the subject of the present invention is used in a radio, in atape recorder, in a compact disc or audio cassette player, in atelevision set or in an audio or multimedia transmitter, and a selectoris used to select the music generation in accordance with the presentinvention.

Another method of implementation is explained with regard to FIGS. 11 to25, by way of nonlimiting example.

In this method of implementation described and shown, all the randomselections made by the central processing unit 1106 relate to positiveor negative numbers and a selection made from an interval bounded by twovalues may give one of these two values.

During an operation 1200, the synthesizer is initialized and switched tothe General MIDI mode by sending MIDI-specific codes. It consequentlybecomes a “slave” MIDI expander ready to be read and to carry outorders.

During operations 1202 and 1204, the central processing unit 1106 readsthe values of the constants, corresponding to the structure of the pieceto be generated, and stored in the read-only memory (ROM) 1105, and thentransfers them to the random-access memory (RAM) 1104.

In order to define the internal structure of a beat (FIG. 12, 1150), thevalue 4 is given for the maximum number of possible locations to beplayed per beat, 4 locations called “e1”, “e2”, “e3” and “e4”(terminology specific to the invention). Each beat of the entire piecehas 4 identical locations. Other modes of application may employ adifferent value or even several values corresponding to binary orternary divisions of the beat. Example, for a ternary division of thebeat: 3 locations per beat, i.e. 3 quavers in triplets in a 2/4 bar, 4/4bar, 6/4 bar, etc., or 3 crotchets in triplets in a 2/2 bar, 3/2 bar,etc. This therefore gives only 3 locations, “e1”, “e2” and “e3”, perbeat. The number of these locations determines certain of the followingoperations.

Again during operation 1202, the central processing unit 1106 also readsthe constant value 4, corresponding to the internal structure of the bar(FIG. 12, 1150, 1160). This value defines the number of beats per bar.

Thus, the overall structure of the piece will be composed of 4-beat bars(4/4), where each beat may contain a maximum of 4 semiquavers, providing16 (4×4) positions of notes, of note duration or of rests per bar. Thissimple measurement choice is decided arbitrarily in order to make iteasier to the reader to understand.

During operation 1204, the central processing unit 1106 reads values ofconstants corresponding to the overall structure of the piece (FIG. 13,1204) and more specifically to the lengths, in terms of bars, of the“moments”. Couplet and refrain each receive a length value in terms ofbeats equal to 8. Couplet and refrain therefore represent a total of 16bars of 4 beats each containing 4 locations. That is a total of timeunits or “positions” of

16×4×4=256 positions.

Also read are the values corresponding to the number of repeats of the“moments” during the playing phase. During the playing phase, theintroduction will be the reading and the playing of the first two barsof the couplet, played twice—the “couplet and refrain” will each beplayed twice and the finale (coda) will be the repeat of the refrain,these arbitrary values possibly being, in other modes of application,different or the same, between random imposed limits.

During operations 1202 and 1204, and after each reading of the constantsstored in the read-only memory (ROM) 1105, the central processing unit1106 transfers these structure values into the random-access memory(RAM) 104.

During an operation 1206, the central processing unit 1106 reservestables of associated variables (within the beat) and of allocation oftables of whole numbers, each table being composed of 256 entries,corresponding to the 256 positions of the piece (J=1 to 256). The valuespossibly reserved by each table are set to zero (for the case in whichthe program is put into a loop so as to generate continuous music). Themain tables thus reserved, allocated and initialized are (FIG. 12,1170):

the harmonic chord table;

the melody rhythmic cadence table;

the melody note pitch table;

the melody note length (duration) table;

the melody note intensity table;

the arpeggio note rhythmic cadence table;

the arpeggio note pitch table;

the arpeggio note intensity table;

the rhythmic chord rhythmic cadence table;

the rhythmic chord intensity table.

Then, during an operation 1208, the central processing unit 1106 makes arandom orchestra selection from a set of orchestras composed ofinstruments specific to a given musical style (variety, classical,etc.), this orchestra value being accompanied by values correspondingto:

the type of instrument (or sound);

the settings of each of these instruments (overall volume,reverberation, echoes, panning, envelope, clarity of sound, etc.), whichdetermines the following operations.

These values are stored in memory in the “instrumentation” register ofthe random-access memory 1104.

Next, during an operation 1212, the central processing unit 1106randomly selects the tempo of the piece to be generated, in the form ofa clock value corresponding to the duration of a time unit (“position”),that is to say, in terms of note length, of a semiquaver expressed in{fraction (1/200)}^(th) of a second. This value is selected at randombetween 17 and 37. For example, the value 25 corresponds to a crochetduration of 4×{fraction (25/200)}^(th) of a second=½ second, i.e. atempo of 120 to the crotchet. This value is stored in memory in the“tempo” register of the random-access memory 1104.

The result of this operation has an influence on the followingoperations, the melody and the musical arrangement being denser (morenotes) if the tempo is slow, and vice versa.

Then, during an operation 1214, the central processing unit 1106 makes arandom selection between −5 and +5. This value is stored in memory inthe “transposition” register of the random-access memory 1104.

The transposition is a value which defines the tonality (or baseharmony) of the piece; it transposes the melody and its accompaniment byone or more semitones, upward or downward, with respect to the firsttonality, of zero value, stored in the read-only memory.

The base tonality of value “0” being arbitrarily C major (or itsrelative minor, namely A minor).

During an operation 1220, the central processing unit makes a binaryselection and, during a test 1222, determines whether the value selectedis equal to “1” or not. When the result of the test 1222 is negative,one of the preprogrammed sequences of 8 chords (1 per bar) is selectedfrom the read-only memory 1105—operations 1236 to 1242. If the result ofthe test 1222 is positive, the chords are selected, one by one, randomlyfor each bar—operations 1224 to 1234.

During operation 1236, the central processing unit randomly selects twonumbers between “1” and the “total number” of preprogrammed chordsequences contained in the “chord” register of the read-only memory1105. Each chord sequence comprises eight chord numbers, eachrepresented by a number between 0 and 11 (chromatic scale, semitone bysemitone, from C to B), alternating with eight mode values (major=0,minus=1).

For example, the following sequence of 8 chords and 8 modes:

9, −1, 4, −1, 9, −1, 4, −1, 7, 0, 7, 0, 0, 0, 0, 0 corresponds to thetable below:

Chords A min E min A min E min G G C C Values 9 4 9 4 7 7 0 0 Maj/min −1−1 −1 −1 0 0 0 0

In this table, in the “Maj/min” row, each major chord is represented bya zero and each minor chord by “−1”.

It will be seen later, during operation 1411, that a table of chordinversions, whose values are 1, 2 and 3, is associated with each chordsequence.

During an operation 1238, these various values are written anddistributed in the chord table at the positions corresponding to thelength of the couplet (positions 1 to 128).

During an operation 1240, a procedure identical to operation 1236 iscarried out, but this time for the refrain.

During an operation 1242, these various values are written anddistributed in the chord table at the positions corresponding to thelength of the refrain (positions 129 to 256).

When the result of the test 1222 is positive, the central processingunit 1106 randomly selects a single preprogrammed chord from theread-only memory 1105 and then, during operation 1228 and starting fromposition 17 (J=17), compares the chord selected with the chord of theprevious bar (J=J−16). The chord compared is accepted or rejectedaccording to the rules of the art (adjacent tones, relative minors,dominant seventh chords, etc.). If the chord is rejected, during anoperation 1226 a new chord selection is made only for the same position“J” until the chord is accepted. Next, during operation 1230, the chordvalue is copied, together with its mode and inversion values, from therandom-access memory in the chord table, into the 16 positions of thecurrent bar.

Each bar is thus processed in increments of 16 positions, carried out byoperation 1234. The test 1232 checks whether the “J” position is not thelast position of the piece (J=(256−16)+1), i.e. the first position ofthe last bar.

Operation 1230, on the one hand, and operations 1238 and 1242, on theother hand, make it possible, in the rest of the execution of the flowchart, to know the current chord at each of the 256 positions of thepiece.

In general, these operations relating to the chords of the piece to begenerated may be shown schematically:

An operation of randomly selecting preprogrammed chord sequencesintended for each of the two fundamental moments: couplet then refrain.

An operation of randomly selecting chords from available chords, foreach bar, according to the constraints of the rules of the art, thechoice of one or other of the above two operations itself being random.

It should be mentioned here that the method of implementation describedand shown generates musical pieces of the “song” or “easy listening”style, the available chords are also intentionally limited to thefollowing chords: perfect minors, perfect majors, diminished chords,dominant sevenths, elevenths. The harmony (chord) participates in thedetermination of the music style. Thus, to obtain a “Latin-American”style, for example, requires a library of chords comprising majorsevenths, augmented fifths, ninths, etc.

FIG. 15 combines the operations of randomly generating one of the threerhythmic cadences of two bars, each one distributed over the entirepiece, determining the positions of the melody notes to be played andmore precisely the positions of the starts (“notes-on”) of the note tobe played of the melody, the other positions being consequently rests,note durations or ends of note duration (or “notes-off”, described laterin “duration of the notes”).

Example of a rhythmic cadence of two 4/4 bars, i.e. of 32 positions:

Bars: 1 2 Beats: 1 2 3 4 1 2 3 4 Locations: 1234 1234 1234 1234 12341234 1234 1234 Positions to 1000 1010 0000 1000 1000 0000 1110 0000 beplayed:

The row of the positions to be played represent the rhythmic cadence,the number “1” indicating the position which will later receive a notepitch and the number “0” indicating the positions which will receiverests, or, as we will see later, note durations (or lengths), and“notes-off”.

The couplet receives the first two cadences repeated 2 times and therefrain receives the third cadence repeated 4 times.

The operation of generating a rhythmic cadence is carried out in foursteps so as to apply a density coefficient specific to each location(“e1” to “e4”) within the beat of the bar. The values of thesecoefficient determine, consequently, the particular rhythmic cadence ofa given style of music.

For example, a density equal to zero, and applied to each of thelocations “e2” and “e4” consequently produces a melody composed only ofquavers at the locations “e1” and “e3”. On the other hand, a maximumdensity applied to the four locations consequently produces a melodycomposed only of semiquavers at the locations “e1”, “e2”, “e3” and “e4”(general rhythmic cadence of a fugue).

Selection of the random rhythmic cadences of the melody, that is to sayselection of the “positions to be played” within the (universal) beat atlocations “e1” to “e4” takes place in an anticipatory manner, in thiscase by increments of four in 4 positions:

in a first beat, it is necessary to deal with the positions at thelocations “e1”

positions 1, 5, 9, 13, . . . up to 253;

in a second beat, the positions at the locations “e3”

positions 3, 7, 11, 15, . . . up to 255;

next, indiscriminately, the other locations “e2” and “e4”

positions 2, 6, 10, 14, . . . up to 254;

positions 4, 8, 12, 16, . . . up to 256.

The positions are therefore not treated chronologically except,obviously, during the first treatment of the positions at “e1”. Thismakes it possible, for the following selections (in the order: positions“e3”, “e2” and “e4”), to know the previous time adjacency (the past) andthe next time environment (the future) of the note to be treated (exceptat “e1” where only the previous one is known from the second one to beselected).

Knowing the past and the future of each position will determine thedecisions to be taken for the various treatments at “e3”, “e2” and then“e4” (the presence or absence of a note at the preceding and followinglocations determining the existence of the note to be treated and, lateron, the same principle will be applied to the selection of the notepitches in order to deal with the intervals, doublets, durations, etc.).

Here, the beat is divided into four semiquavers, but this principleremains valid for any other division of the beat.

EXAMPLE

In the present method of implementation, the existence of a note at thelocations “e2” and “e4” is determined by the presence of a note, eitherat the previous position or at the following position. In other words,if this position has no immediate adjacency, either before or after, itcannot be a position to be played and will be a rest position,note-duration position or note-off position.

In the method of implementation described and shown, the variouscadences have a length of two bars and there are therefore eightpossible locations (“e1” to “e4”) of notes to be played:

the locations “e1” of the first part of the couplet have a densityallowing a minimum number of 2 notes for two bars and a maximum numberof 6 notes for two bars;

the locations “e3” of the first part of the couplet have a densityallowing a minimum number of 5 notes for two bars and a maximum numberof 6 notes for two bars;

the locations “e2” and “e4” of the first part of the couplet have a verylow density, namely 1 chance in 12 of having a note at these locations;

the locations “e1” of the second part of the couplet have a densityallowing a minimum number of 5 notes for two bars and a maximum numberof 6 notes for two bars;

the locations “e3” of the second part of the couplet have a densityallowing a minimum number of 4 notes for two bars and a maximum numberof 6 notes for 2 bars;

the locations “e2” and “e4” of the second part of the couplet have avery low density, namely 1 chance in 12 of having a note at theselocations;

the locations “e1” of the (entire) refrain have a density allowing aminimum number of 6 notes for two bars and a maximum number of 7 notesfor two bars;

the locations “e3” of the refrain have a density allowing a minimumnumber of 5 notes for two bars and a maximum number of 6 notes for twobars;

the locations “e2” and “e4” of the refrain have a very low density,namely 1 chance in 14 of having a note at these locations.

This density option consequently produces a rhythmic cadence of the“song” or “easy listening” style. The density of the rhythmic cadence isinversely proportional to the speed of execution (tempo) of the piece;in addition, the faster the piece the lower the density.

If the test 1278 is positive, a binary selection is made during anoperation 1250. If the result of the selection is positive, the rhythmiccadences of the melody are generated according to the random mode.

During an operation 1254, the density is selected for each location “e1”to “e4” of one of the three cadences of two bars to be generated (twofor the couplet and only one for the refrain). The counter “J” of thepositions is initialized to the first position (J=1) during operation1256, so as firstly to treat the positions at the locations “e1”.

Next, during an operation 1258, a binary selection (“0” or “1”) is madeso as to determine whether this “J” position has to receive a note ornot. As mentioned above, the chances of obtaining a positive result arehigher or lower depending on the location in the beat (here “e1”) of theposition to be treated. The result obtained (“0” or “1”) is written intothe melody rhythmic cadence table at the position J.

If the result of the test 1260 is negative, that is to say there remainpositions at the locations “e1” in the cadence of two current bars, J isincremented by the value “4” in order to “jump” to the next position“e1”.

If the result of the test 1260 is positive, the test 1266 checks whetherall the positions of all the locations have been treated. If this test1266 is negative, an operation 1264 initializes the position J accordingto the new location to be treated. In order to treat the locations “e1”,J was initialized to 1, and in order to handle

the locations “e3”, the initialization is

the locations “e2”, the initialization is

the locations “e4”, the initialization is J=4.

Thus, the loop of operations 1254, 1256, 1258, 1206 and 1266 is carriedout as long as the test 1266 is negative.

This same process is employed for each of the 3 cadences of two bars(two for the couplet and one for the refrain).

If the result of the test 1252 is negative, an operation 1268 randomlyselects one of the cadences of two bars, preprogrammed in the read-onlymemory 1105.

This same process is employed for each of the 3 cadences of two bars(two for the couplet and one for the refrain).

If the result of the test 1266 is positive, an operation 1269 copies the3 rhythmic cadences obtained into the entire piece in the table ofrhythmic cadences of the melody:

the first cadence of two bars (i.e. 32 positions) is copied twice intothe first four bars of the piece. At this stage, half the couplet istreated, i.e. 64 positions;

the second cadence of two bars (i.e. 32 positions) is reproduced twiceover the next four bars. At this stage, the entire couplet is treated,i.e. 128 positions;

the third and final cadence of two bars (i.e. 32 positions) isreproduced 4 times over the next eight bars. At this stage, all of thecouplet and of the refrain have been treated, i.e. 256 positions.

Next, during operations 1270 to 1342, the note pitches are selected atthe positions defined by the rhythmic cadence (positions of notes to beplayed).

A note pitch is determined by five principal elements:

the overall basic harmony;

the chord associated with the same position of the piece;

its location (“e1” to “e4”) within the beat of its own bar;

the interval which separates it from the previous note pitch, and in thenext note; and

its possible immediate adjacency (presence of a note in the previousposition or (and) next position.

In addition, as was carried out during the selection of the rhythmiccadence of the melody, an anticipatory selection of the note pitches ofthe melody is made, in part. The positions of notes to be played overthe entire piece, which are defined by the (above) rhythmic cadence ofthe melody, are not treated chronologically:

an operation of generating two “families of notes” is formed:

a first family of notes called “base notes” which is formed by the notesmaking up the chord “associated with the position” of the note to betreated and

a family of notes called “passing notes” consisting of the notes of thescale of the overall base harmony (current tonality) reduced or not bythe notes making up the chord associated with the position of the noteto be treated.

In the method of implementation described and shown, the family ofpassing notes consists of the notes of this scale is reduced by thenotes making up the associated chord so as to avoid successiverepetitions of the same note pitches (doublets).

For example, in the scale of C, the notes underlined makeup the chord ofF and form the family of base notes. The other notes form the family ofpassing notes: A, B, C, D, E, F, G, A, B, C, D, E, F, etc.

In the method of implementation described and shown, and apart fromexceptions described above, the melody consists of an alternation ofpassing notes and of base notes.

H3/Selection of the note pitches of the melody (FIGS. 16 to 19).

For a clearer understanding by the reader, what is repeated below isonly the note pitches at the positions to be played, these being definedby the rhythmic cadence of the melody, and the selections are random.There is obviously no anticipation during the first selection of each ofthe two following operations.

A first operation (FIG. 16) of anticipating the selection of the notepitches from the family of “base notes”, where only the positions placedat the start of the beat (“e1”) are treated (positions 1, 5, 9, 13, 17,etc.).

A second operation (FIG. 17) of anticipating the selection of the notepitches from the family of “passing notes”, where only the positionsplaced at the “half-beat” (“e3”) are treated (positions 3, 7, 11, 15,19, etc.).

A third operation (FIG. 18) of selecting the note pitches at thelocations “e2” (positions 2, 6, 10, 14, 18, etc.). This selection ismade from one or other family depending on the possible previousadjacency (note or rest) at “e1” and (or) the following one at “e3”(FIG. 24). Depending on the case, this selection may cause a change inthe family of the next note at “e3” so as to comply with the basenote/passing note alternation imposed here (FIG. 24).

A fourth operation (FIG. 19) of selecting note pitches at the locations“e4” (positions 4, 8, 12, 16, 20, etc.). This selection is made from oneor other family depending on the possible previous adjacency (note orsilence) at “e3” and (or) the next one at “e1” (FIG. 24). Depending onthe case, this selection may cause a change in the family of theprevious note at “e3” so as to comply with the base note/passing notealternation imposed here (FIG. 25).

Exceptions to the base note/passing note alternation:

the last note of a musical phrase is selected from the family of basenotes, whatever are the location (“e1” to “e4”) within the beat of thecurrent bar (FIG. 20), here a note at the end of a phrase is regarded asif it is followed by a minimum of 3 positions of rests (without a note);

the note at “e4” is selected from the family of base notes if there is achord change at the next position at “e1”.

For certain styles (e.g. American variety, jazz), a passing noterepresenting a second (note D of the the melody with, in theaccompaniment, a common chord of C major) at the location “e1” isacceptable (even if the chord is a perfect chord of C major) whereas inthe method of implementation (song style) described and shown, only thebase notes are acceptable at “e1”.

The operations and tests in FIG. 16 relate to the selection of the notesto be played at the locations “e1” and, as previously, in the selectionof the rhythmic cadences, the treatment of the positions in question iscarried out in increments of 4 positions (positions 1, then 5, then 9,etc.).

During an operation 1270, the “J” position indicator is initialized tothe position “1”, and then during the test 1272 the central processingunit 1106 checks, in the melody rhythmic cadence table, if the “J”position corresponds to a note to be played.

If the test 1272 is positive, after having read the current chord (atthis same position J), the central processing unit 1106 randomly selectsone of the note pitches from the family of base notes.

It is recalled that the positions at the locations “e1” receive onlynotes of the base family, except in the very rare exception alreadydescribed.

During a test 1276, and obviously based on the second position to betreated, the central processing unit 1106 checks if the previouslocation (“e1”) is a position of a note to be played. If this is thecase, the interval separating the two notes is calculated. If thisinterval (in semitones) is too large, the central processing unit makesa new selection at 1274 for the same position J.

The maximum magnitude of an interval allowed between the notes of thelocations “e1” has here a value of 7 semitones.

If the test 1276 is positive, the note pitch is placed in the note pitchtable at the position J. Next, the test 1278 checks whether “J” is thelast location “e1” to be treated. If this is not the case, the variable“J”, corresponding to the position of the piece, is incremented by 4 andthe same operations 1272 to 1278 are carried out for the new position.

If the test 1272 is negative (there is no note at the position “J”), “J”is incremented by 4 (next position “e1” ) and the same operations 1272to 1278 are carried out for the new position.

The operations and tests in FIG. 17 relate to the selection of the notesto be played at the locations “e3” and thus, as previously, in theselection at the locations “e1”, the positions in question are treatedin increments of 4 positions (position 3, then position 7, then position11, etc.).

During an operation 1270 a, the “J” position indicator is initialized tothe position “3” and then, during the test 1272 a, the centralprocessing unit 1106 checks in the table of rhythmic cadences for themelody, whether the position “J” corresponds to a note to be played.

If the test 1272 a is positive, after having read the current chord (atthis same position J) and the scale of the base harmony (tonality) inorder to form the family of passing notes which was described above, thecentral processing unit 1106 randomly selects one of the note pitchesfrom the family of passing notes.

The positions at the locations “e3” receive notes of the passing family,given the very low density of the “e2” and “e4” passing notes in thismethod of implementation (in the song style).

These notes at “e3” will possibly be corrected later, during selectionsrelating to the positions at the locations “e2” and “e4” (FIGS. 24 and25).

For other music styles, such as a fugue for example, the densities ofthe four locations is very high, this having the effect of generating anote to be played per location (“e1” to “e4”), i.e. four semiquavers perbeat for a 4/4 bar. In this case, in order to comply with thealternation imposed in the method of implementation described and shown(base note then passing note), the note pitches at the locations “e3”would be selected from the family of base notes:

“e1”=base note, “e2”=passing note,

“e3”=base note, “e4”=passing note.

In the method of implementation described and shown (in which the notes,at the locations “e2” and “e4” of the beat, are very rare given thedensity chosen), the family of passing notes is chosen for the notes tobe played at the locations “e3” since usually the result of theselections is as follows for each beat:

“e1”=base note “e2”=rest, “e3”=passing note, “e4”=rest.

And so on; there is indeed an alternation of base notes and passingnotes imposed by the method of implementation described and shown.

During a test 1276 a, the central processing unit 1106 looks for theprevious position to be played (“e1” or “e3”) and the note pitch at thisposition. The interval separating the two notes is calculated. If thisinterval is too large, the central processing unit 1106 makes a newselection at 1274 a for the same position J.

The maximum allowed magnitude of the interval between the notes of thelocations “e3” and their previous note has here a value of 5 semitones.

If the test 1276 a is positive, the note pitch is placed in the table ofnote pitches at the position J. The test 1278 a then checks whether “J”is the last location “e3” to be treated. If this is not the case, thevariable “J” corresponding to the position of the piece is incrementedby four and the same operations 1272 a to 1278 a are carried out for thenew position.

If the test 1272 a is negative (there is no note at the position “J”),“J” is incremented by 4 (next position “e1”) and the same operations1272 a to 1278 a are carried out at the new position.

The operations in FIG. 18 relates to the selection of the notes to beplayed at the locations “e2”. As previously, in the selection at thelocations “e1” and then “e3”, the positions in question are treated inincrements of 4 positions (position 2, then position 6, then position10, etc.).

During an operation 1310, the “J” position indicator is initialized tothe position “2” and then, during the test 1312, the central processingunit 1106 checks in the table of rhythmic cadences for the melodywhether the position “J” corresponds to a note to be played.

If the test 1312 is positive, during an operation 1314, the centralprocessing unit reads, from the table of chords at the position “J”, thecurrent chord and the scale of the base harmony (tonality). The centralprocessing unit 1106 then randomly selects one of the note pitches fromthe family of passing notes.

The positions at the locations “e2” always receive notes of the passingfamily, except if:

they are isolated, that is to say without a note immediately in front ofit (past note) and without a note immediately after it (future note);

there is not not a note to be played and placed at the next (future)position at “e3”.

In these cases, the locations “e2” receive base notes. Again here, theadvantage of the anticipatory selection procedure may be seen.

The presence of a note to be played at “e2” implies the correction ofthe next and immediately adjacent note at “e3” (FIG. 24).

The central processing unit 1106 looks for the previous position to beplayed (“e1” or “e3”) and the note pitch at this position. The intervalseparating the previous note from the note in the process of beingselected is calculated. If this interval is too large, the test 1318 isnegative. The central processing unit 1106 then makes, during anoperation 1316, a new selection at the same position J.

The maximum allowed magnitude of the interval between the notes of thelocations “e2” and the previous (past) note on the one hand and the next(future) note on the other hand has, in this case, a value of 5semitones.

If the test 1318 is positive, the note pitch is placed in the table ofnote pitches at the position J.

During an operation 1320, and if the selection of the next position(J+1) is made from the family of passing notes (as is the case here),the central processing unit 1106 reselects (corrects) the note locatedat the next position (J+1 at “e3”) but this time the selection is madefrom the notes of the base family in order to comply with the “basenote/passing note” alternation imposed here.

Next, the test 1322 checks whether “J” is the last location “e2” to betreated. If this is not the case, the variable “J” corresponding to theposition of the piece is incremented by 4 and the same operations 1312to 1322 are carried out at the new position J.

If the test 1322 is negative (there is no note at the position “J”), andduring an operation 1324, “J” is incremented by 4 (next position “e2”)and the same operations 1312 to 1322 are carried out at the newposition.

The operations and tests in FIG. 19 relate to the selection of notes tobe played at the locations “e4”. As previously, in the selection at thelocations “e1”, “e3” then “e2”, the positions in question are treated inincrements of 4 positions (position 2, then position 6, then position10, etc.).

During an operation 1330, the “J” position indicator is initialized tothe position “4” and then, during the test 1332, the central processingunit 1106 checks, in the table of rhythmic cadences for the melody, ifthe position “J” corresponds to a note to be played.

If the test 1332 is positive, the central processing unit 1106 duringanother rest 1334 checks whether the chord located at the next positionJ+1 is different from that of the current position J.

If the result of the test 1334 is negative, the central processing unit1106 during an operation 1336 reads, from the table of chords at theposition “J”, the current chord and the scale of the base harmony(tonality). The central processing unit 1106 then randomly selects oneof the note pitches from the family of passing notes.

The positions at the locations “e4” always receive notes of the passingfamily apart from in the following exceptional cases:

the chord placed at the next position J+1 is different from that of thecurrent position “J”;

the position to be treated is isolated, that is to say without a noteimmediately in front of it (past note) and without a note immediatelyafter it (future note);

the next position (future position at “e1”) is a rest position.

In all these exceptional cases, the position at the location “e4”receives a base note.

The presence of a note to be played at “e4” implies correction of theprevious and immediately adjacent note at “e3” (FIG. 25).

During a test 1339, the central processing unit 1106 looks for theprevious position to be played (“e1”, “e2” or “e3”) and then the notepitch at this position.

The interval separating the previous note from the note currentlyselected is calculated. If this interval is too large, the test 1339 isnegative. The central processing unit 1106 then makes, during anoperation 1336, a new selection at the same position J.

The maximum allowed magnitude of the interval between the notes of thelocations “e4” and the previous (past note) on the one hand and the next(future note) on the other hand has, here, a value of 5 semitones.

If the test 1339 is positive, the note pitch is placed in the table ofnote pitches at the position J.

During an operation 1340, and if the selection of the previous position(J−1) is made from the family of passing notes, the central processingunit 1106 reselects (corrects) the note located at the previous position(J−1, and therefore at “e3”), but this time the selection is made fromthe notes of the base family in order to comply with the “basenote/passing note” alternation imposed here.

Next, the test 1342 checks whether “J” is the last location (“e4”) to betreated. If this is not so, the variable “J” corresponding to theposition of the piece is incremented by 4 and the same operations 1332to 1342 are carried out for the new position J.

If the test 1342 is negative (there is no note at the position “J”), andduring an operation 1344, “J” is incremented by 4 (next position“e4”)—thus the same operations 1332 to 1342 are carried out at the newposition.

Next, FIG. 20 shows the operations (again relating to the notes of themelody):

of calculating the note lengths (durations);

of selecting the intensities (volume) of the notes;

of looking for and correcting the notes located at the end of thevarious musical phrases generated previously.

These operations are performed chronologically from the “1” position tothe “256” position.

During an operation 1350, the variable “J” is initialized to 1 (firstposition) and then, during a test 1352, the central processing unit 1106reads, from the table of the rhythmic cadences for the melody, whetherthe position “J” has to be played.

If the test 1352 is positive (the current position “J” is a position tobe played), the central processing unit 1106 counts the positions ofrests located after the current “J” position (the future).

During an operation 1354, the central processing unit 1106 calculatesthe duration of the note placed at the position J: the number (aninteger) corresponding to half the total of the positions of restsfound.

A “1” value indicating a “note off” is placed in a subtable of notedurations, which also has 256 positions, at the position correspondingto the end of the last position of the duration. This instruction willbe read, during the playing phase, and will allow the note to be “cutoff” at this precise moment.

The “note off” determines the end of the length of the previous note,the shortest length here being a semiquaver (a single position of thepiece).

Example: 4 blank positions have been found after a note placed at the“1” position (J=1). The duration of the note is then 2 positions (4/2 .. . it is recalled here that these are positions on a timescale) towhich is added the duration of the initial position “J” of the noteitself, i.e. a total duration of 3 positions corresponding here to 3semiquaver rests, i.e. a dotted quaver rest.

Here the quavers which follow one another are linked together (only asingle blank position between them).

Other systems for calculating the note durations may be produced forother methods of implementation or other music styles:

quantization of the rest: a duration corresponding to a multiple of thetime unit, here a semiquaver, i.e. in rest value a semiquaver rest);

maximum extension of the duration for songs referred to as“broad-sweeping”;

splitting the initial duration into two for notes played staccato;

durations chosen by random selection, these being limited by the numberof rest positions available (between 1 and 7, for example).

During an operation 1355, the central processing unit 1106 reads thevarious intensity values from the read-only memory 1105 and assigns themto the melody note intensity table according to:

the location (“e1” to “e4”) of the notes within the beat; and

their position in the piece.

Intensities of the notes to be played as a function of their locationwithin the beat of the bar:

Location Intensity (MIDI code: 0 to 127) “e1” 65 “e2” 75 “e3” 60 “e4” 58

The intensity of the notes, with respect to the locations, contributesto giving the music generated a character or style.

Here, the intensity of the notes at the end of a phase is equal to 60(low intensity) unless the note to be treated is isolated by more than 3positions of rests in front of it (in the past) and after it (in thefuture), where in this case the intensity of the note is equal to 80(moderately high intensity).

Next, during a test 1356, the central processing unit 1106 checkswhether the number of rests lying after the note and calculated duringoperation 1353 is equal to or greater than 3.

If the test 1356 is positive and the note to be played at the position“J” is from the family of passing notes, the note at the currentposition (J) is regarded as a “note at the end of a musical phrase” andmust absolutely be taken from the family of base notes during operation1360.

Next, a test 1362 checks whether the position J is equal to 256 (end ofthe tables). If the test 1362 is negative, “J” takes the value J+1 andthe operations and tests 1352 to 1362 are carried out again at the newposition.

If the test 1362 is positive, a binary selection operation is carriedout in order to decide the method of generating the rhythmic cadence ofthe arpeggios.

When the result of the selection is positive, the value 1 is assigned tothe variable J during an operation 1372.

Next, during an operation 1374 a binary random selection is made.

When the result of the selection in operation 1374 is positive, a value“1” is written into the arpeggio rhythmic cadence table.

Next, the test 1376 checks if J=16.

It should be mentioned here that two different cadences of a bar (16positions) are selected randomly and repeated, one over the entire 8bars of the couplet and the other over the entire 8 bars of the refrain.

The operations relating to a single cadence are represented here in FIG.21, those relating to the second cadence being identical.

If the test 1376 is negative, J is incremented by “1” during anoperation 1377 and the operations 1374 to 1376 are carried out again.

If the test 1376 is positive, the central processing unit 1106 during anoperation 1378 puts an identical copy of this cadence bar into all thebars of the moment in question (couplet or refrain).

If the test 1370 is negative, the central processing unit 1106, duringan operation 1371, randomly selects one of the bars (16 positions) ofrhythmic cadences preprogrammed in the read-only memory 1105.

Then, during an operation 1380, J is reinitialized, taking the value“1”.

Next, during a test 1382, the central processing unit 1106 checks in themelody rhythmic cadence table whether this position “J” is a positionfor a note to be played.

If the result of the test 1382 is positive, the central processing unit,during an operation 1384, reads the current chord and then randomlyselects a note of the base family.

Next, during an operation 1386, the central processing unit makes acomparison of the interval of the note selected and the previous note.

If the interval exceeds the maximum allowed interval (in this case 5semitones), operation 1384 is repeated.

If the interval does not exceed the maximum allowed interval, thecentral processing unit then randomly selects, during an operation 1387,the intensity of the arpeggio note from the numbers read from theread-only memory (e.g. 68, 54, 76, 66, etc.) and writes it into thetable of the intensities of the arpeggio notes at the position J.

During the test 1388, the central processing unit checks if J=256.

If the test 1388 is negative, the value J is incremented by 1 andoperations 1382 to 1388 are repeated at the new position.

If the test 1388 is positive, during operation 1400 the value J isinitialized to the value “1”.

During a test 1404, the central processing unit reads from the arpeggiotable whether an arpeggio note to be played at the location J exists.

If the result of the test 1404 is positive, the position J of the chordrhythmic cadence table keeps a value “0” during operation 1406.

Then, during a test 1412, the central processing unit checks whetherJ=256.

If the result of the test 1412 is negative, the variable J isincremented by “1” and operation 1404 is then repeated.

If the result of the test 1404 is negative, during operation 1408 theposition J in the chord rhythmic cadence table takes the value “1”(chord to be played when there is no arpeggio note to be played).

Next, during operation 1410, the central processing unit 1106 makes aselection from two values (in this case 54 and 74) of rhythmic chordintensities stored in the read-only memory 1105 and writes it into thetable corresponding to the position J.

Next, during operation 1411, the central processing unit 1106 selectsone of the two values (1, 2 or 3) of rhythmic chord inversion stored inthe read-only memory 1105 and writes it into the table of chordinversions at the position J.

Each of these values defines the place of the notes to be played in thechord. Example of inversions of a chord of C major:

inversion 1=C3, E3, G3 (tonic, third, fifth);

inversion 2=G3, C3, E3 (fifth, tonic, third);

inversion 3=E3, G3, C3 (third, fifth, tonic);

the numbers “2”, “3” and “4”, placed after the note, indicating theoctave pitch.

Next, during a test 1412, the central processing unit 1106 checkswhether J is equal to 16 (end of the cadence bar).

If the test 1412 is negative, during an operation 1414 J is incrementedby “1” and operation 1404 is repeated for the new position J.

If the test 1412 is positive, during an operation 1416:

the cadence value is copied into the entire couplet (positions 1 to 128)in the “chord rhythmic cadence” subtable;

the intensity value is copied into the entire couplet (positions 1 to128) in the “rhythmic chord intensity” subtable;

the inversion value is copied into the entire couplet (positions 1 to128) in the “rhythmic chord inversion” subtable.

It should be pointed out that operations 1400 to 1416 above relating tothe couplet are the same for the refrain (positions 129 to 256).

Next, during an operation 1420, the central processing unit sends thevarious General MIDI configuration, instrumentation and sound-settingparameters to the synthesizer 1109 via the MIDI interface 113. It willbe recalled that the synthesizer was initialized during operation 1200.

Next, during operation 1422, the central processing unit initializes theclock to t=0.

Next, if the value of “t” is 20, all of the results of the operations atposition “J” described below (and shown in FIG. 23) will be sent to thesynthesizer.

These signals are sent every {fraction (20/200)}^(th) of a second, andfor each position (1 to 256), respecting the repeats of the various“moments”.

Next, during an operation 1424, the position “J” is initialized andreceives the value. “1”.

During an operation 1426, the central processing unit 1106 reads thevalues of each table and sends them to the synthesizer 1428 in a MIDIprotocol form.

After all the playing parameters have been sent, the central processingunit 1106 waits for the {fraction (20/200)}^(th) of a second haveelapsed (t=t+20 in the example chosen).

During operation 1431, the central processing unit reinitializes “t”(“t”=0).

Next, during a test 1434, the central processing unit 1106 checkswhether the position J is the end of the current “moment” (end of theintroduction, of the couplet, etc.).

If the test 1434 is negative, the central processing unit 1106 thenchecks, during a test 1436, whether the position J (depending on thevalues of repeats) is not that corresponding to the end of the piece.

If the test 1436 is negative, J is incremented by 1 during operation1437 and then operation 1426 is repeated.

If the test 1434 is positive, the situation corresponds to the start ofa “moment” (e.g. the start of a couplet).

It will be recalled that the introduction has a length of 2 bars (theseare the first two bars of the couplet), the couplet has a length of 8bars and the refrain a length of 8 bars.

Each moment is played successively two times and the finale (coda) isthe repetition of the refrain (three times with fade out).

In addition, during operation 1435, the variable J takes the followingvalues in succession:

end of the introduction: J=J−32

end of the couplet: J=J−(8×16)

end of the refrain: J=J−(8×16)

repetition of the refrain (coda) J=J−(8×16)

Next, operation 1426 is repeated at the new position J.

If the test 1436 is positive, the set of operations is completed, unlessthe entire music generation process described above is put into a loop.In this case, continuous music is heard.

Then, depending on the computation speed of the microprocessor used, thevarious pieces form a sequence after a silence of a few tenths of asecond, during which the “partition” of a new piece is generated.

What is claimed is:
 1. An automatic music generation procedure, whereinit comprises: an operation of defining musical moments during which atleast four notes are capable of being played; an operation of definingtwo families of note pitches, for each musical moment, the second familyof note pitches having at least one note pitch which is not in the firstfamily; an operation of forming at least one succession of notes havingat least two notes, each succession of notes being called a musicalphrase, in which succession, for each moment, each note whose pitchbelongs exclusively to the second family is surrounded exclusively bynotes of the first family; and an operation of outputting a signalrepresentative of each note pitch of each said succession.
 2. The musicgeneration procedure as claimed in claim 1, wherein, during theoperation of defining two families of note pitches, for each musicalmoment, the first family is defined as a set of note pitches belongingto a chord duplicated from octave to octave.
 3. The music generationprocedure as claimed in claim 2, wherein, during the operation ofdefining two families of note pitches, the second family of note pitchesincludes at least the note pitches of a range which are not in the firstfamily of note pitches.
 4. The music generation procedure as claimed inclaim 1, wherein, during the operation of forming at least onesuccession of notes having at least two notes, each musical phrase isdefined as a set of notes the starting times of which are not mutuallyseparated, in pairs, by more than a predetermined duration.
 5. The musicgeneration procedure as claimed in claim 1, wherein it furthermoreincludes an operation of inputting values representative of physicalquantities and in that at least one of the operations of definingmusical moments, of defining two families of note pitches, of forming atleast one succession of notes, is based on at least one value of aphysical quantity.
 6. The music generation procedure as claimed in claim5, wherein said physical quantity is representative of a movement. 7.The music generation procedure as claimed in claim 5, wherein saidphysical quantity is representative of an input on keys.
 8. The musicgeneration procedure as claimed in claim 5, wherein said physicalquantity is representative of an image.
 9. The music generationprocedure as claimed in claim 5, wherein said physical quantity isrepresentative of a physiological quantity of the user's body,preferably obtained by means of at least one of the following sensors:an actimeter; a tensiometer; a pulse sensor; a friction sensor; a sensorfor detecting the pressure at various points on gloves and/or shoes; anda sensor for detecting pressure on arm and/or leg muscles.
 10. The musicgeneration procedure as claimed in claim 1, wherein it comprises: anoperation of processing information representative of a physicalquantity during which at least one value of a parameter called a“control parameter” is generated; an operation of associating eachcontrol parameter with at least one parameter called a “music generationparameter” corresponding to at least two notes to be played during amusical fragment; and a music generation operation using each musicgeneration parameter to generate a musical fragment.
 11. The musicgeneration procedure as claimed in claim 10, wherein the musicgeneration operation comprises, successively: an operation ofautomatically determining a musical structure composed of momentscomprising bars, each bar having times and each time having note startlocations; an operation of automatically determining densities,probabilities of the start of a note to be played, these beingassociated with each location; and an operation of automaticallydetermining rhythmic cadences according to densities.
 12. The musicgeneration procedure as claimed in claim 10, wherein the musicgeneration operation comprises: an operation of automaticallydetermining harmonic chords which are associated with each location; anoperation of automatically determining families of note pitchesaccording to the rhythmic chord which is associated with a position; andan operation of automatically selecting a note pitch associated witheach location corresponding to the start of a note to be played,according to said families and to predetermined composition rules. 13.The music generation procedure as claimed in claim 10, wherein the musicgeneration operation comprises: an operation of automatically selectingorchestral instruments; an operation of automatically determining atempo; an operation of automatically determining the overall tonality ofthe fragment; an operation of automatically determining a velocity foreach location corresponding to the start of a note to be played; anoperation of automatically determining the duration of the note to beplayed; an operation of automatically determining rhythmic cadences ofarpeggios; and/or an operation of automatically determining rhythmiccadences of accompaniment chords.
 14. The music generation procedure asclaimed in claim 13, wherein, during the music generation operation,each density depends on said tempo.
 15. The music generation procedureas claimed in claim 10, wherein said procedure comprises a musicgeneration initiation operation comprising an operation of connection toa network, for example the Internet network.
 16. The music generationprocedure as claimed in claim 10, wherein said procedure comprises amusic generation initiation operation comprising an operation oftransmitting a predetermined play order via a network server to a toolcapable of carrying out the music generation operation.
 17. The musicgeneration procedure as claimed in claim 15, wherein it comprises anoperation of downloading, into the computer of a user, a softwarepackage allowing the music generation operation to be carried out. 18.The music generation procedure as claimed in claim 10, wherein saidprocedure comprises a music generation initiation operation comprisingan operation of reading a sensor.
 19. The music generation procedure asclaimed in claim 1, wherein at least one of the notes has a pitch whichdepends on the pitch of the notes which surround it.
 20. The musicgeneration procedure as claimed in claim 1, wherein it includes a firstoperation of determining the pitch of notes which are positioned atpredetermined locations and a second operation of determining the pitchof other notes during which the pitch of a note depends on the notepitches of the notes which surround said note and which are at saidpredetermined locations.
 21. The music generation procedure as claimedin claim 1, wherein the note pitches are determined in an achronicorder.
 22. An automatic music generation system, wherein it comprises: ameans of defining musical moments during which at least four notes arecapable of being played; a means of defining two families of notepitches, for each musical moment, the second family of note pitcheshaving at least one note pitch which is not in the first family of notepitches; a means of forming at least one succession of notes having atleast two notes, each succession of notes being called a musical phrase,in which succession, for each moment, each note whose pitch belongsexclusively to the second family is surrounded exclusively by notes ofthe first family; and a means of outputting a signal representative ofeach note pitch of each said succession.
 23. The music generation systemas claimed in claim 22, wherein the means of defining two families ofnote pitches is designed to define, for each musical moment, the firstfamily as a set of note pitches belonging to a chord duplicated fromoctave to octave.
 24. The music generation system as claimed in claim23, wherein the means of defining two families of note pitches isdesigned to define the second family of note pitches so that it includesat least the note pitches of a range which are not in the first familyof note pitches.
 25. The music generation system as claimed in claim 22,wherein the means of forming at least one succession of notes having atleast two notes is designed so that each musical phrase is defined as aset of notes the starting times of which are not mutually separated, inpairs, by more than a predetermined duration.
 26. The music generationsystem as claimed in claim 22, wherein it furthermore includes a meansof inputting values representative of physical quantities and in that atleast one of the means of defining musical moments, of defining twofamilies of note pitches, of forming at least one succession of notes,is designed to take into account said value of at least one value of aphysical quantity.
 27. The music generation system as claimed in claim22, wherein it comprises: a means of processing informationrepresentative of a physical quantity designed to generate at least onevalue of a parameter called a “control parameter”; a means ofassociating each control parameter with at least one parameter called a“music generation parameter” each corresponding to at least two notes tobe played during a musical fragment; a music generation means using eachmusic generation parameter to generate a musical fragment.
 28. The musicgeneration system as claimed in claim 22, wherein the means of forming asuccession is designed so that at least one of the notes has a pitchwhich depends on the pitch of the notes which surround it.
 29. The musicgeneration system as claimed in claim 22, wherein the means of forming asuccession is designed to determine pitches of notes positioned atpredetermined locations and to determine pitches of other notes duringwhich the pitch of a note depends on the note pitches of the notes whichsurround said note and which are at said predetermined locations. 30.The music generation system as claimed in claim 22, wherein the means offorming a succession is designed to determine the note pitches in anachronic order.
 31. An electronic and/or video game comprising a musicgeneration system as claimed in claim
 22. 32. The game as claimed inclaim 31, wherein at least one parameter of musical fragments played bymeans of the music generation system depends on a phase of the gameand/or on the results of a player.
 33. A computer comprising a musicgeneration system as claimed in claim
 22. 34. A television transmittercomprising a music generation system as claimed in claim
 22. 35. Atelevision receiver comprising a music generation system as claimed inclaim
 22. 36. A telephone receiver comprising a music generation systemas claimed in claim
 22. 37. The telephone receiver as claimed in claim36, wherein the music generation system is designed to control a musicalringing tone and in that said telephone receiver comprises means forcustomizing said ringing tone by the subscriber.
 38. The telephonereceiver as claimed in claim 36, wherein said telephone receivercomprises means for automatically associating a telephone ringing tonewith the telephone number of the caller.
 39. A datacom server intendedto be connected to a telephone network, comprising a music generationsystem as claimed in claim
 22. 40. A music broadcaster, preferablyconsisting of a synthesizer, comprising a music generation system asclaimed in claim
 22. 41. An electronic chip comprising a musicgeneration system as claimed in claim 22.